package com.ruicar.afs.cloud.afscase.processor.service;

import com.ruicar.afs.cloud.afscase.approvetask.entity.WorkProcessScheduleInfoTemp;
import com.ruicar.afs.cloud.afscase.processor.vo.NormalReformistVO;
import com.ruicar.afs.cloud.afscase.processor.vo.NormalTaskSubmitVO;
import com.ruicar.afs.cloud.workflow.api.dto.flowprocess.WorkFlowResponse;

/**
 * @Description
 * @Author Peng_Jinbo
 * @Date 2020/07/17 15:25
 */
public interface ApproveWorkflowService {

    /**
     * 流程发起
     *
     * @param temp
     * @return
     */
    WorkFlowResponse start(WorkProcessScheduleInfoTemp temp);

    /**
     * 提交
     *
     * @param submitVO
     * @return
     */
    void submit(NormalTaskSubmitVO submitVO);

    /**
     * 改派
     *
     * @param reformistVO
     * @return
     */
    WorkFlowResponse reformist(NormalReformistVO reformistVO);

    /**
     * 流程撤销(审批过程外撤销)
     *
     * @param stageId
     * @return
     */
    WorkFlowResponse cancelFlow(String stageId, String message);


    /**
     * 流程撤销(审批过程外撤销)
     *
     * @param stageId
     * @return
     */
    WorkFlowResponse cancelFlow(String stageId, String message,boolean noticeToApplySys);

    /**
     * @Description 经销商主动撤回
     * @Author ma_xueyu
     * @Date 2020-08-31
     */
    WorkFlowResponse dealerCallBackFlow(NormalTaskSubmitVO submitVO);

    /**
     * @Description 审批人员撤回
     * @param scheduleId 流程实例表ID
     * @param message 撤回备注
     * @param callbackUsername 撤回用户ID
     * @param callBackUserRealName 撤回用户姓名
     * @Author ma_xueyu
     * @Date 2020-09-15
     * */
    WorkFlowResponse callBackFlow(String scheduleId, String message,String callbackUsername,String callBackUserRealName);



    /**
    * @Description 供定时任务调用，人员当日不上岗时，待审核案件回收至待分配任务池
    * @Author Peng_Jinbo
    * @Date 2020/10/12 16:36
    */
    void cronNotOnlineTaskRecycle();
}
